home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
64'er 1985 March
/
64er_Magazin_85-03_1985_Markt__Technik_de.d64
/
son of destroyer
(
.txt
)
< prev
Wrap
Commodore BASIC
|
2022-10-26
|
5KB
|
173 lines
0 rem" ******************************
1 [143]" ** **
2 rem" * [211]on of [196]estroyer *
3 [143]" * ---------------- *
4 rem" * [195]64 - [214]ersion 1.19 *
5 [143]" * valntwurf und (NULL)rogramm von *
6 rem" * [193]ndreas [215]urf *
7 [143]" * *
8 rem" ** **
9 [143]" ******************************
10 :
11 :
15 gosub 10000:rem title
20 gosub 20000:rem helppage
30 gosub 30000:rem set vars
35 gosub 40000:rem params
40 gosub 50000:rem workfield
45 aw$="slh[133][134][135][136][137][138][140][145][157]":dim fu$(len(aw$))
47 dw$="":fori=1 to len(aw$):read fu$(i):next
50 poke vi,peek(vi) or 128
60 poke 198,0:wait 198,1:get t$
70 poke vi,peek(vi)and not 128
80 for i=1 to len(aw$):if t$=mid$(aw$,i,1)then 87
85 next:goto 50
87 print dw$"[198]unction: "fu$(i)"[146] [154]"
90 on i gosub 4000,5000,200,500,800,1000,1300,1600,1900,2500,3000,3100,3200,3300
95 goto 50
200 gosub 20000:gosub 50000:return
500 poke vi,42:return
800 poke vi,46:return
1000 for i=0 to 20:if peek(vi+i*40)<>46 and peek(vi+i*40)<>42 then 1010
1005 poke vi+i*40,42:next
1010 for i=1 to 20:if peek(vi-i*40)<>46 and peek(vi-i*40)<>42 then 1020
1015 poke vi-i*40,42:next
1020 return
1300 for i=0 to 20:if peek(vi+i*40)<>46 and peek(vi+i*40)<>42 then 1310
1305 poke vi+i*40,46:next
1310 for i=1 to 20:if peek(vi-i*40)<>46 and peek(vi-i*40)<>42 then 1320
1315 poke vi-i*40,46:next
1320 return
1600 open 15,gn,15:open 2,gn,2,"#":v=1868
1605 for t=0 to 34:for s=0 to 20
1610 p=peek(v-(s*40)+t):poke v-(s*40)+t,peek(v-(s*40)+t) or 128
1620 if p<>42 then 1665
1630 print#15,"u1:"2;0;t+1;s
1640 print#15,"m-w";chr$(me);chr$(0);chr$(1);chr$(ko)
1650 print#15,"u2:"2;0;t+1;s
1660 print#15,"m-w";chr$(me);chr$(0);chr$(1);chr$(kn)
1665 poke v-(s*40)+t,peek(v-(s*40)+t) and 127
1666 get t$:if t$<>"*" then 1670
1668 printdw$;" [198]unction aborted [146][154] ":close2:close15:return
1670 next s,t:input#15,f1$,f2$,f3$,f4$:print""f1$" "f2$" "f3$" "f4$
1680 close 2:close 15:return
1900 open 15,gn,15:open 2,gn,2,"#":v=1868
1905 for t=0 to 34:for s=0 to 20
1910 p=peek(v-(s*40)+t):poke v-(s*40)+t,peek(v-(s*40)+t) or 128
1920 if p<>42 then 1945
1925 print#15,"m-w";chr$(me);chr$(0);chr$(1);chr$(ko)
1930 print#15,"u1:"2;0;t+1;s
1935 print#15,"m-w";chr$(me);chr$(0);chr$(1);chr$(kn)
1940 print#15,"u2:"2;0;t+1;s
1945 poke v-(s*40)+t,peek(v-(s*40)+t) and 127
1950 get t$:if t$<>"*" then 1970
1960 printdw$;" [198]unction aborted [146][154] ":close2:close15:return
1970 next s,t:input#15,f1$,f2$,f3$,f4$:print""f1$" "f2$" "f3$" "f4$
1980 close 2:close 15:return
2100 gosub 40000:goto 50
2500 print dw$" [199]oodbye ":end
3000 if peek(vi-40)=42 or peek(vi-40)=46then vi=vi-40:return
3005 return
3100 if peek(vi+40)=42 or peek(vi+40)=46then vi=vi+40:return
3105 return
3200 if peek(vi-1)=42 or peek(vi-1)=46 then vi=vi-1:return
3205 return
3300 if peek(vi+1)=42 or peek(vi+1)=46 then vi=vi+1:return
3305 return
4000 rem ** save workpage **
4010 :
4020 open 15,gn,15:v=1868
4030 print#15,"s:sod.temp":open 2,8,2,"sod.temp,u,w":print#2,gn:print#2,ko
4040 for t=0 to 34:for s=0 to 20
4050 print#2,chr$(peek(v-(s*40)+t));
4060 next s,t:close 2
4070 input#15,f1$,f2$,f3$,f4$:close 15
4080 print""f1$" "f2$" "f3$" "f4$
4090 return
5000 rem ** load workpage **
5010 :
5020 open 15,gn,15:v=1868:open 2,gn,2,"sod.temp,u,r":input#2,gn:input#2,ko
5030 for t=0 to 34:for s=0 to 20
5040 get#2,a$:a$=a$+chr$(0)
5050 poke v-(s*40)+t,asc(a$)
5060 next s,t:close 2
5070 input#15,f1$,f2$,f3$,f4$:close 15
5080 print""f1$" "f2$" "f3$" "f4$
5090 return
9999 stop
10000 rem ** ausgabe des kopfblattes **
10001 rem ** und vorbereiten des **
10002 rem ** des bildschirms **
10003 :
10010 poke 646,peek(53280):print"[147]"chr$(9);chr$(14);chr$(8);
10020 print" [211] [207] [206] [207] [198] [196] [197] [211] [212] [210] [207] [217] [197] [210] "
10030 print"[145] ================================= "
10040 print"[145] "
10050 print"[145] *** *** "
10060 print" [197]in [208]rogramm zum [218]erstoeren und"
10070 print" [215]iederherstellen von [196]isk-[194]locks."
10075 print" [196]er [201]nhalt dieser [194]locks bleibt"
10077 print" vollstaendig erhalten."
10080 print" *** [196]ruecke [210][197][212][213][210][206][146] ***
10090 [161] t$:[139] t$[179][177][199](13) [167] 10090
10095 [142]
10096 :
10097 :
20000 [143] ** ausgabe des helpblattes **
20003 :
20020 [153]"load (NULL) (NULL) (NULL) (NULL) asc str$ val (NULL) (NULL) (NULL) (NULL) (NULL) val (NULL) "
20030 [153]"on ================================= "
20040 [153]"on left$elp - (NULL)age "
20050 [153]" atnllocate peeklock => asc1 wait
20060 print" [198]ree [194]lock => [198]3 [146]
20070 [153]" atnllocate (NULL)rack => asc5 wait
20080 print" [198]ree [212]rack => [198]7 [146]
20090 [153]" str$estroy str$isk => asc2 wait
20100 print" [210]ebuild [196]isk => [198]4 [146]
20110 [153]" atnbort ascunction => * wait
20115 print" [200]elp-[208]age => h [146]
20117 [153]" (NULL)ave (NULL)age => s wait
20118 print" [204]oad [208]age => l [146]
20120 [153]" (NULL)uit (NULL)rogram => asc8 wait
20140 print" *** [208]ress [210][197][212][213][210][206][146] ***"
20150 wait 198,1:get t$:if t$<>chr$(13) then 20150
20160 return
20161 :
20162 :
30000 rem ** setzen der parameter **
30001 :
30010 gn=8:ko=139:vi=1868:me=71:kn=7:return
30011 :
30012 :
40000 rem ** anpassen der parameter **
40001 :
40010 print"[147] [211] [207] [206] [207] [198] [196] [197] [211] [212] [210] [207] [217] [197] [210] "
40020 print"[145] ================================= "
40030 print"[145] [211]et [208]arameters "
40040 open 1,0:print""
40050 print" [196]evice # :"gn"[145]":print"";:input#1,gn:print""
40070 print" [195]onstant :"ko"[145]":print"";:input#1,ko:print""
40080 close 1:if gn<8 or gn>14 then 40010
40100 if ko<0 or ko>255 then 40010
40110 return
50000 print"[147]";
50005 print" [201]/[207]: 00 ok 00 00 [145]":print"[145]";
50010 tr$=" ..................................."
50020 for i=0 to 20:print tr$:next
50030 print"[216][216][216][216][216][216][216][216][216][216][216][216][216][216][216][216][216][216]
50035 [153]"(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)(NULL)
50040 print"[216][216][216][216][216][216][216][216][216][216][216]
50050 [153]"(NULL)(NULL)(NULL)(NULL)(NULL)
50060 print"";:for i=20 to 0 step-1:print" "i:next
50070 print"12345678901234567890123456789012345"
50080 print" [212]racks[146] 11111111112222222222333333"
50090 print"":tr$="[211]ectors"
50095 for i=1 to len(tr$):print""mid$(tr$,i,1):next:return
63040 :
63050 rem ** data's fuer funktionen **
63060 :
63065 data "[211]ave [208]age","[204]oad [208]age"
63070 data "[200]elp-[208]age","[193]llocate [194]lock","[198]ree [194]lock","[193]llocate [212]rack"
63080 data "[198]ree [212]rack","[196]estroy [196]isk","[210]ebuild [196]isk"
63090 data "[209]uit [208]rogram","up","down","left","right"